//Tue 19 Jan 2010 05:34:13 PM CST 
#include <vector>
#include <list>
#include <map>
#include <set>
#include <deque>
#include <queue>
#include <stack>
#include <bitset>
#include <algorithm>
#include <functional>
#include <numeric>
#include <utility>
#include <sstream>
#include <iostream>
#include <iomanip>
#include <cstdio>
#include <cmath>
#include <cstdlib>
#include <cctype>
#include <string>
#include <cstring>
#include <cstdio>
#include <cmath>
#include <cstdlib>
#include <ctime>

using namespace std;

class Inequalities
{
public:
	int maximumSubset(vector<string> inequalities)
	{
		int ret = 0;
		int N = inequalities.size();
		vector<double> solution;
		vector<pair<string, double> > v;
		for(int i=0; i<N; i++)
		{
			string x;
			string s;
			double num;
			stringstream ss(inequalities[i]);
			ss >> x >> s >> num;
			solution.push_back(num);
			solution.push_back(num+0.5);
			solution.push_back(num-0.5);
			v.push_back(make_pair(s, num));
		}
		for(int i=0; i<solution.size(); i++)
		{
			int count = 0;
			for(int j=0; j<v.size(); j++)
			{
				if(v[j].first == "<") count += (solution[i]<v[j].second);
				if(v[j].first == "<=") count += (solution[i]<=v[j].second);
				if(v[j].first == "=") count += (solution[i]==v[j].second);
				if(v[j].first == ">") count += (solution[i]>v[j].second);
				if(v[j].first == ">=") count += (solution[i]>=v[j].second);
			}
			ret = max(ret, count);
		}
		return ret;
	}
};
//From exod40;
